home *** CD-ROM | disk | FTP | other *** search
- /*
- * The original copyright owners of the accompanying source code files have
- * agreed to place such code into the public domain. Accordingly, anyone
- * who receives or obtains a copy of such source code is freely entitled to
- * reproduce, use and otherwise exploit such code (including the right to
- * make derivative works), at his/her own risk and expense, without any
- * obligation or liability to the original copyright owners.
- *
- * We would appreciate (but do not require) that the following message be
- * included in any derivative works:
- *
- * "Portions of this program were developed by Peter Broadwell, Rob Myers
- * and Robin Schaufler while working in Silicon Valley."
- *
- * The accompanying source code files and related documentation materials
- * are distributed on an "AS IS" basis, without any warranties or
- * guarantees of any kind. All implied warranties, including the implied
- * warranties of merchantability and of fitness for any particular purpose,
- * are expressly disclaimed.
- */
- #include "gl.h"
-
- #include "geom.h"
- #include "class.h"
- #include "classIds.h"
- #include "selectors.h"
- #include "mbox.h"
- #include "colors.h"
- #include "panel.h"
- #include "menu.h"
-
- extern class panelClass;
-
- extern char *selectMenu(), *drawMenu(), *eselMenu();
- extern char *cascadeMenu();
-
- fcnTable menuTable[] = {
- ENDSELECT, eselMenu, /* end picking on a menu */
- SELECT, drawMenu,
- TRANSACT, selectMenu,
- DRAWTRACKER,NULL,
- EOTABLE,
- };
-
- class menuClass = {
- &panelClass,
- menuTable,
- sizeof(menu),
- MENU,
- };
-
- menu menuTemplate = {
- /* inst */
- &menuClass, /* myClass pointer */
- NULL, /* classFunctions */
- 0, /* nFunctions */
- /* mailbox */
- NULL, /* subscribers */
- NULL, /* subscribedTo */
- /* panel */
- NULL, /* next */
- NULL, /* kids */
- NULL, /* dad */
- 0,0,0,0, /* area */
- NULL, /* painter */
- /* menu */
- 0,0, /* nbuttons */
- 0, /* curVal */
- NULL, /* receiver */
- 0, /* baseSelect */
- NULL, /* highlight */
- };
-
- fcnTable bhmenuTable[] = {
- TRANSACT, cascadeMenu,
- EOTABLE,
- };
-
- class bhmenuClass = {
- &menuClass,
- menuTable,
- sizeof(menu),
- BHMENU,
- };
-
- menu bhmenuTemplate = {
- /* inst */
- &bhmenuClass, /* myClass pointer */
- NULL, /* classFunctions */
- 0, /* nFunctions */
- /* mailbox */
- NULL, /* subscribers */
- NULL, /* subscribedTo */
- /* panel */
- NULL, /* next */
- NULL, /* kids */
- NULL, /* dad */
- 0,0,0,0, /* area */
- NULL, /* painter */
- /* menu */
- 0,0, /* nbuttons */
- 0, /* curVal */
- NULL, /* receiver */
- 0, /* baseSelect */
- NULL, /* highlight */
- };
-
- extern char *selectChoice(), *drawChoice();
-
- fcnTable choiceTable[] = {
- SELECT, selectChoice,
- TRANSACT, NULL,
- DRAWTRACKER,drawChoice,
- EOTABLE,
- };
-
- class choiceClass = {
- &panelClass,
- choiceTable,
- sizeof(choice),
- CHOICE,
- };
-
- choice choiceTemplate = {
- /* inst */
- &choiceClass, /* myClass pointer */
- NULL, /* classFunctions */
- 0, /* nFunctions */
- /* mailbox */
- NULL, /* subscribers */
- NULL, /* subscribedTo */
- /* panel */
- NULL, /* next */
- NULL, /* kids */
- NULL, /* dad */
- 0,0,0,0, /* area */
- NULL, /* painter */
- /* menu */
- 0,0, /* nbuttons */
- 0, /* curVal */
- NULL, /* baseChoice */
- NULL, /* value */
- NULL, /* highlight */
- };
-
- extern char *selectChoicef(), *drawChoicef();
-
- fcnTable choicefTable[] = {
- SELECT, selectChoicef,
- TRANSACT, NULL,
- DRAWTRACKER,drawChoicef,
- EOTABLE,
- };
-
- class choicefClass = {
- &panelClass,
- choicefTable,
- sizeof(choicef),
- CHOICEF,
- };
-
- choicef choicefTemplate = {
- /* inst */
- &choicefClass, /* myClass pointer */
- NULL, /* classFunctions */
- 0, /* nFunctions */
- /* mailbox */
- NULL, /* subscribers */
- NULL, /* subscribedTo */
- /* panel */
- NULL, /* next */
- NULL, /* kids */
- NULL, /* dad */
- 0,0,0,0, /* area */
- NULL, /* painter */
- /* menu */
- 0,0, /* nbuttons */
- 0, /* curVal */
- NULL, /* baseChoice */
- NULL, /* value */
- NULL, /* highlight */
- };
-